package com.fengye.aop.demo.service.account.impl;

import com.fengye.aop.demo.anotation.WorkflowAnnotation;
import com.fengye.aop.demo.service.account.IAccountService;
import org.springframework.stereotype.Service;

/**
 * @author fengyexjtu@126.com
 * @since 2022-09-23
 */
@Service
public class AccountService implements IAccountService {
    @Override
    public String testBefore() {
        System.out.println("程序正常执行");
        System.out.println("将执行 before 方法");
        return "testBefore";
    }
    
    @Override
    @WorkflowAnnotation(record = true)
    public String testAround() {
        System.out.println("程序正常执行");
        System.out.println("将执行 around 方法");
        return "testAround";
    }
    
    @Override
    public String noAnnotation(){
        System.out.println("程序正常执行 - noAnnotation");
        System.out.println("将执行 around 方法");
        return "noAnnotation";
    }
}
